package edu.xlh.travel.enumeration;

import java.util.Arrays;
import java.util.HashSet;
import java.util.Set;

public enum EmailTypeEnum {
    order("0", "下单成功"),
    arrange("1" , "安排入住"),
    relet("2", "续租"),
    checkOut("3", "退房申请中"),
    checkOutSuccess("4", "退房成功"),
    paySuccess("5", "支付成功"),
    ;
    private static final Set<String> enumSet = new HashSet<>(50);

    static {
        Arrays.asList(SFTPOperateTypeEnum.values()).forEach(e -> enumSet.add(e.getCode()));
    }

    public static boolean hasEnum(String code) {
        return enumSet.contains(code);
    }

    //code
    private String code;

    //描述
    private String desc;

    EmailTypeEnum(String code, String desc) {
        this.code = code;
        this.desc = desc;
    }

    public String getCode() {
        return code;
    }
    public String getDesc() {
        return desc;
    }
}
